package cn.bob.exception;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * @author bob
 * @data 2022/11/17-10:51
 */
@Getter
@AllArgsConstructor
public enum GlobalExceptionEnum {
    //所有的成功失败提示
    OK("成功了","1"),
    FAIL("失败了","-1"),

    //common异常由1xxx开头
    COMMON_PARAM_IS_NULL_ERROR("参数为空异常","1001"),
    COMMON_PARAM_ILLEGAL_ERROR("非法参数异常","1002"),
    COMMON_PARAM_JSR303_ERROR("JSR303参数异常","1003"),
    COMMON_PARAM_IMGSMS_ERROR("生成验证码失败！","1004"),
    COMMON_RIDES_IMGSMS_ERROR("图形验证码错误！","1005"),
    COMMON_PHONE_IS_NULL_ERROR("手机号为空异常！","1006"),
    COMMON_PHONE_FORMAT_ERROR("手机号格式错误！","1007"),

    //system异常由2xxx开头

    //user异常由3xxx开头
    USER_PHONE_REGISTERED_ERROR("该手机号已注册过了！！","2001");
    //uaa异常由4xxx开头
    ;
    //创建错误码和信息
   private String massage;
   private String exceptionCode;


}
